package com.xidian.zhiancloud.controller.cgs.TrainManager;

import com.xidian.zhiancloud.dto.ResultDTO;
import com.xidian.zhiancloud.dto.TrainDto.TrainPlanAndTrainContentsDTO;
import com.xidian.zhiancloud.enums.GeneralResponseEnums;
import com.xidian.zhiancloud.service.cgs.TrainManager.TrainPlanService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * 教育培训-培训计划
 * @Author: chenguosong
 * @Date: 2020/11/20 00:34
 * @mail 2581592671@qq.com
 */
@RestController
//@RequestMapping("/TrainPlan")
public class TrainPlanController {
//    @Autowired
//    private TrainPlanService trainPlanService;
//
//    @PostMapping("/add")
//    public ResultDTO<Boolean> add(@RequestBody TrainPlanAndTrainContentsDTO trainPlanAndTrainContentsDTO) {
//        trainPlanService.add(trainPlanAndTrainContentsDTO);
//        return ResultDTO.successOf(GeneralResponseEnums.SUCCESS);
//    }
//
//    @DeleteMapping("/{id}")
//    public ResultDTO deleteById(@PathVariable Long id) {
//        trainPlanService.deletebyid(id);
//        return ResultDTO.successOf(GeneralResponseEnums.SUCCESS);
//    }
//
//    @GetMapping("/getListPlan")
//    public ResultDTO listPlan(@RequestParam(value = "current", required = false, defaultValue = "0") int current,
//                              @RequestParam(value = "size", required = false, defaultValue = "10") int size) {
//        return ResultDTO.successOf(trainPlanService.getListPlan(current, size), GeneralResponseEnums.SUCCESS);
//    }
//
//    @GetMapping("/getListPlanContent")
//    public ResultDTO listContent(@RequestParam(value = "current", required = false, defaultValue = "0") int current,
//                                 @RequestParam(value = "size", required = false, defaultValue = "10") int size,
//                                 @RequestParam(value = "trainPlanId", required = true) Long trainPlanId) {
//        return ResultDTO.successOf(trainPlanService.getListPlanContent(current, size,trainPlanId), GeneralResponseEnums.SUCCESS);
//    }
//
//    @PostMapping("/update")
//    public ResultDTO update(@RequestBody TrainPlanAndTrainContentsDTO trainPlanAndTrainContentsDTO) {
//        trainPlanService.update(trainPlanAndTrainContentsDTO);
//        return ResultDTO.successOf(GeneralResponseEnums.SUCCESS);
//    }
}
